package com.hibernate.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.JoinColumns;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.hibernate.annotations.GenericGenerator;
import org.hibernate.javacommon.base.BaseEntity;

/**
 * 
 */
@Entity
@Table(name = "REPORT_CATEGORY_AD")
@org.hibernate.annotations.Entity(mutable=false)
public class ReportCategoryAd extends BaseEntity implements java.io.Serializable{
	
	private static final long serialVersionUID = -5128631239848997260L;
	
	private Long id;
	private Long userId;
	private Long adOwnerId;
	private Long adOrderId;
	private Long adPlanId;
	private Long materialId;
	private Long channelsId;
	private Long websiteId;
	private Long labelId;
	private Long adSiteId;
	private Long categoryId;
	private Long showPv;
	private Long showUv;
	private Long clickPv;
	private Long clickUv;
	private java.lang.String logDate;

	public ReportCategoryAd(){
	}
	
	public void setId(Long value) {
		this.id = value;
	}
	
	@Id 	@GeneratedValue(generator = "paymentableGenerator")       
	@GenericGenerator(name = "paymentableGenerator", strategy = "native") 
	@Column(name = "ID", unique = true, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getId() {
		return this.id;
	}
	
	@Column(name = "USER_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getUserId() {
		return this.userId;
	}
	
	public void setUserId(Long value) {
		this.userId = value;
	}
	
	@Column(name = "AD_OWNER_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getAdOwnerId() {
		return this.adOwnerId;
	}
	
	public void setAdOwnerId(Long value) {
		this.adOwnerId = value;
	}
	
	@Column(name = "AD_ORDER_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getAdOrderId() {
		return this.adOrderId;
	}
	
	public void setAdOrderId(Long value) {
		this.adOrderId = value;
	}
	
	@Column(name = "AD_PLAN_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getAdPlanId() {
		return this.adPlanId;
	}
	
	public void setAdPlanId(Long value) {
		this.adPlanId = value;
	}
	
	@Column(name = "MATERIAL_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getMaterialId() {
		return this.materialId;
	}
	
	public void setMaterialId(Long value) {
		this.materialId = value;
	}
	
	@Column(name = "CHANNELS_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getChannelsId() {
		return this.channelsId;
	}
	
	public void setChannelsId(Long value) {
		this.channelsId = value;
	}
	
	@Column(name = "WEBSITE_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getWebsiteId() {
		return this.websiteId;
	}
	
	public void setWebsiteId(Long value) {
		this.websiteId = value;
	}
	
	@Column(name = "LABEL_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getLabelId() {
		return this.labelId;
	}
	
	public void setLabelId(Long value) {
		this.labelId = value;
	}
	
	@Column(name = "AD_SITE_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getAdSiteId() {
		return this.adSiteId;
	}
	
	public void setAdSiteId(Long value) {
		this.adSiteId = value;
	}

	@Column(name = "CATEGORY_ID", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getCategoryId() {
		return categoryId;
	}

	public void setCategoryId(Long categoryId) {
		this.categoryId = categoryId;
	}
	
	@Column(name = "SHOW_PV", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getShowPv() {
		return this.showPv;
	}
	
	public void setShowPv(Long value) {
		this.showPv = value;
	}
	
	@Column(name = "SHOW_UV", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getShowUv() {
		return this.showUv;
	}
	
	public void setShowUv(Long value) {
		this.showUv = value;
	}
	
	@Column(name = "CLICK_PV", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getClickPv() {
		return this.clickPv;
	}
	
	public void setClickPv(Long value) {
		this.clickPv = value;
	}
	
	@Column(name = "CLICK_UV", unique = false, nullable = false, insertable = true, updatable = true, length = 20)
	public Long getClickUv() {
		return this.clickUv;
	}
	
	public void setClickUv(Long value) {
		this.clickUv = value;
	}
	
	@Column(name = "LOG_DATE", unique = false, nullable = false, insertable = true, updatable = true, length = 10)
	public java.lang.String getLogDate() {
		return this.logDate;
	}
	
	public void setLogDate(java.lang.String value) {
		this.logDate = value;
	}
	
	private Material material;
	public void setMaterial(Material material){
		this.material = material;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "MATERIAL_ID",nullable = false, insertable = false, updatable = false) 
	})
	public Material getMaterial() {
		return material;
	}
	
	private Channels channels;
	public void setChannels(Channels channels){
		this.channels = channels;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "CHANNELS_ID",nullable = false, insertable = false, updatable = false) 
	})
	public Channels getChannels() {
		return channels;
	}
	
	private AdPlan adPlan;
	public void setAdPlan(AdPlan adPlan){
		this.adPlan = adPlan;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "AD_PLAN_ID",nullable = false, insertable = false, updatable = false) 
	})
	public AdPlan getAdPlan() {
		return adPlan;
	}
	
	private Label label;
	public void setLabel(Label label){
		this.label = label;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "LABEL_ID",nullable = false, insertable = false, updatable = false) 
	})
	public Label getLabel() {
		return label;
	}
	
	private AdOrder adOrder;
	public void setAdOrder(AdOrder adOrder){
		this.adOrder = adOrder;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "AD_ORDER_ID",nullable = false, insertable = false, updatable = false) 
	})
	public AdOrder getAdOrder() {
		return adOrder;
	}
	
	private AdOwner adOwner;
	public void setAdOwner(AdOwner adOwner){
		this.adOwner = adOwner;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "AD_OWNER_ID",nullable = false, insertable = false, updatable = false) 
	})
	public AdOwner getAdOwner() {
		return adOwner;
	}
	
	private AdSite adSite;
	public void setAdSite(AdSite adSite){
		this.adSite = adSite;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "AD_SITE_ID",nullable = false, insertable = false, updatable = false) 
	})
	public AdSite getAdSite() {
		return adSite;
	}

	private Website website;
	public void setWebsite(Website website){
		this.website = website;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "WEBSITE_ID",nullable = false, insertable = false, updatable = false) 
	})
	public Website getWebsite() {
		return website;
	}

	private CategoryInfo categoryInfo;

	public void setCategoryInfo(CategoryInfo categoryInfo) {
		this.categoryInfo = categoryInfo;
	}
	
	@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name = "CATEGORY_ID",nullable = false, insertable = false, updatable = false) 
	})
	public CategoryInfo getCategoryInfo() {
		return categoryInfo;
	}
	@Transient
	@Override
	public String getTarget() {
		// TODO Auto-generated method stub
		return null;
	}
	@Transient
	@Override
	public Long getTargetId() {
		// TODO Auto-generated method stub
		return null;
	}
	@Transient
	@Override
	public String getTargetName() {
		// TODO Auto-generated method stub
		return null;
	}
}

